package com.intigas.sysgas.model;

import java.io.Serializable;
import javax.persistence.*;

/**
 * The primary key class for the cfg_clientes database table.
 * 
 */
@Embeddable
public class CfgClientePK implements Serializable {
	//default serial version id, required for serializable classes.
	private static final long serialVersionUID = 1L;
	private String clcia;
	private String clruc;

    public CfgClientePK() {
    }

	@Column(unique=true, nullable=false, length=2)
	public String getClcia() {
		return this.clcia;
	}
	public void setClcia(String clcia) {
		this.clcia = clcia;
	}

	@Column(unique=true, nullable=false, length=11)
	public String getClruc() {
		return this.clruc;
	}
	public void setClruc(String clruc) {
		this.clruc = clruc;
	}

	public boolean equals(Object other) {
		if (this == other) {
			return true;
		}
		if (!(other instanceof CfgClientePK)) {
			return false;
		}
		CfgClientePK castOther = (CfgClientePK)other;
		return 
			this.clcia.equals(castOther.clcia)
			&& this.clruc.equals(castOther.clruc);

    }
    
	public int hashCode() {
		final int prime = 31;
		int hash = 17;
		hash = hash * prime + this.clcia.hashCode();
		hash = hash * prime + this.clruc.hashCode();
		
		return hash;
    }
}